package com.firebird.app.kotlin.stock.trend.fragment

import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.ScrollView
import androidx.fragment.app.Fragment
import com.firebird.app.kotlin.stock.trend.view.StockFSView
import com.firebird.app.kotlin.stock.trend.view.StockTextDataTabView
import com.firebird.app.kotlin.stock.trend.view.StockWdMxTabView
import com.firebird.app.kotlin.stock.trend.R

/**
 * 显示个股分时走势详情
 * @author ljk
 * @date   2019年10月30日
 */
class FragmentStockFenShi : Fragment() {
    private var stockWdmxTabView: StockWdMxTabView? = null
    private var stockTextTabView: StockTextDataTabView? = null
    private var stockFSView: StockFSView? = null
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
    }

    override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View {
        val view = inflater.inflate(R.layout.fragment_stock_fenshi, null) as ScrollView
        //初始化五档/明细TabView菜单控件
        stockWdmxTabView = view.findViewById<View>(R.id.tab_wdmx) as StockWdMxTabView
        stockWdmxTabView!!.setOnClickListener(stockWdmxTabView)
        //初始化新闻资讯TabView菜单控件
        stockTextTabView = view.findViewById<View>(R.id.tab_stocktext) as StockTextDataTabView
        stockTextTabView!!.setOnClickListener(stockTextTabView!!)
        stockTextTabView!!.setParentScrollView(view)
        //初始化分时走势控件
        stockFSView = view.findViewById<View>(R.id.stock_sf) as StockFSView
        return view
    }

    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
        super.onViewCreated(view, savedInstanceState)
    }

    override fun onStart() {
        super.onStart()
    }
}